import Axios from '@/http'
import type {BookParams} from './index_type'
const http = new Axios({
    timeout:5000,
    baseURL:'/admin'
});

// 检查用户是否为管理员
export const checkUserIsAdmin = () => {
    return http.get('/')
}

//获取首页频道列表
export const homeChannelListApi = () => {
    return http.get('/index_channel')
}
//获取小说(单个或多个分页)
export const bookApi = (params:BookParams = {})=>{
    return http.get('/book',params)
}